//package org.ricks.net.balancer;
//
//public abstract class AbstractConsumerLoadBalancer implements IConsumerLoadBalancer {
//
//    public static AbstractConsumerLoadBalancer valueOf(String loadBalancer) {
//        AbstractConsumerLoadBalancer balancer = switch (loadBalancer) {
//            case "random" -> RandomLoadBalancer.getInstance();
//            case "consistent-hash" -> ConsistentHashLoadBalancer.getInstance();
//            case "cached-consistent-hash" -> CachedConsistentHashLoadBalancer.getInstance();
//            default ->
//                    throw new RuntimeException(StringUtils.format("Load balancer is not recognized[{}]", loadBalancer));
//        };
//        return balancer;
//    }
//
//}
